﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using FbKPI.Model;
using FbKPI.Controller;

namespace FbKPI.Facade
{
    public class JobPositionFacade
    {
        public string Save(JobPosition JobPositions)
        {
            JobPositionController cont = new JobPositionController();
            return cont.Save(JobPositions);
        }

        public string Delete(JobPosition JobPositions)
        {
            JobPositionController cont = new JobPositionController();
            return cont.Delete(JobPositions);
        }

        public string BeforeDelete(JobPosition JobPositions)
        {
            JobPositionController cont = new JobPositionController();
            return cont.BeforeDelete(JobPositions);
        }

        public IList<JobPosition> GetAll(string sSearch, int PageNumber, int DataLength, string SortCol, string SortDirection, out int TotalData, int BusinessGroupID)
        {
            IList<JobPosition> JobPositions = new List<JobPosition>();
            JobPositionController cont = new JobPositionController();
            JobPositions = cont.GetAll(sSearch, PageNumber, DataLength, SortCol, SortDirection, out TotalData, BusinessGroupID);
            return JobPositions;
        }

        public JobPosition GetJobPositionByID(int ID)
        {
            JobPosition JobPositions = new JobPosition();
            JobPositionController cont = new JobPositionController();
            JobPositions = cont.GetJobPositionByID(ID);
            return JobPositions;
        }

        public JobPosition GetJobPositionByDescription(string JobPositionDescription)
        {
            JobPosition JobPositions = new JobPosition();
            JobPositionController cont = new JobPositionController();
            JobPositions = cont.GetJobPositionByDescription(JobPositionDescription);
            return JobPositions;
        }
    }
}